package com.sayice.design.lab2_1;

import com.sayice.design.lab2_1.factory.ShapeFactory;
import com.sayice.design.lab2_1.shape.Shape;
import com.sayice.design.util.XmlParse;
import org.xml.sax.SAXException;

import java.io.IOException;

/**
 * @author shubing
 */
public class Client {
    public static void main(String[] args) throws IOException, SAXException {
        String shapeName = new XmlParse("shapeConfig.xml").stringOfTag("shapeName");
        Shape shape = ShapeFactory.getShape(shapeName);
        shape.draw();
        shape.erase();
    }
}
